import random

set1 = {
    1001: "张三",
    1002: "李四",
    1003: "王五"
}


def student(set_stu, id):
    print(set_stu[id])


def student_all(set_stu):
    for key in set_stu:
        print(f"{key}: {set_stu[key]}")
    return None


student(set1, 1001)
student_all(set1)

set1 = set(random.randint(1, 10) for i in range(10))
list1 = list(set1)
print(list1)

studentZhang = {"物理", "数学", "化学"}
studentLi = {"物理", "文言文", "英语"}

print(studentZhang.intersection(studentLi))


def age(n):
    if n == 1:
        return 10
    else:
        return age(n - 1) + 2


print(age(5))
